import axios from '../utils/utils'

//添加分类
export const typeadd = params => axios.post('/goods/addcate', params)

//获取分类
export const gettype = params => axios.get('/goods/catelist', { params })

//添加商品
export const itemadd = params => axios.post('/goods/add', params)

//获取商品列表
export const itemlist = params => axios.get('/goods/list', { params })

//删除分类
export const deltype = params => axios.get('/goods/delcate', { params })

//删除商品
export const delitem = params => axios.get('/goods/del', { params })

//修改分类
export const editcate = params => axios.post('/goods/editcate', params)

//查询所有分类
export const categories = params => axios.get('/goods/categories', { params })

//修改商品
export const edit = params => axios.post('/goods/edit', params)
